package com.ruoyi.find.config;

import org.springframework.context.annotation.Configuration;
import io.swagger.v3.oas.models.OpenAPI;
import io.swagger.v3.oas.models.info.Info;
import io.swagger.v3.oas.models.info.License;
import io.swagger.v3.oas.models.tags.Tag;
import org.springframework.context.annotation.Bean;

@Configuration
public class Knife4jConfig {
    @Bean
    public OpenAPI springShopOpenAPI() {
        return new OpenAPI()
                .info(new Info()
                        .title("房屋租赁系统API文档")
                        .description("房屋租赁系统提供的RESTful API接口文档")
                        .version("v1.0")
                        .license(new License()
                                .name("Apache 2.0")
                                .url("http://springdoc.org")))
                .addTagsItem(new Tag().name("房屋模块").description("房屋相关接口"))
                .addTagsItem(new Tag().name("家具模块").description("家具相关接口"))
                .addTagsItem(new Tag().name("用户模块").description("用户相关接口"));
    }
}